//新增学生
$('#addStudentsBtn').click(function(){
    //获取到学生姓名的值
    const name = $('#addStudentsName').val();
    const age = $('#addStudentsAge').val();
    const gender = $('[name=addStudentsGender]:checked').val();
    //专业_id
    const subjectsId = $('#studentsSubject').val();
    //班级
    const classesId = $('#ban1').val();
    $.ajax({
        url:('/students/createStudents'),
        type:'post',
        data:{
            name,
            age,
            gender,
            subjectsId,
            classesId
        },
        success(res) {
            console.log('新增结果', res);
        }
    })
})